package com.gigi.model;

import io.swagger.annotations.ApiModel;
import lombok.Data;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull;
import java.util.List;

@ApiModel("课程实体")
@Data
public class CourseDO {

    private Long id;

    @NotNull(message = "课程码不能为空")
    private Long no;

    private String pic;

    @NotBlank(message = "课程名不能为空")
    private String name;

    private String classesIdStr;

    @NotEmpty(message = "上课班级不能为空")
    private List<String> classesId;

    // 发布人
    @NotNull(message = "用户id不能为空")
    private Long userId;

    @NotNull(message = "有效性不能为空")
    private Integer flag;

    // 老师名
    private String teacherName;

}
